home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Info-Mac 4
/
Info_Mac IV CD-ROM (Pacific HiTech Inc.)(August 1994).iso
/
Science
/
RLaB
/
help
/
ones
< prev
next >
Wrap
Text File
|
1994-04-25
|
431b
|
20 lines
ones:
Syntax: ones ( M , N )
ones ( A )
Description:
Create a matrix of ones. If the input is two scalars, then
create a matrix of 1s with dimensions NxM.
If the input is a 2 element matrix, then create a matrix with
row and column dimensions equal to A[1] and A[2] respectively.
This is useful when used in conjunction with size():
ones( size( X ) )
will return a matrix of ones the same size as X.
See Also: zeros